//
// Created by root on 2022/3/17.
//
#include <stdio.h>

#define STACK_MAX     1000
// 栈
static int stack[STACK_MAX];
// 栈指针，指向当前的位置
static int current = -1;

void push(int num){
    stack[++current] = num;
    if(current == 1000){
        printf("长度超过 %d,不能再玩了", STACK_MAX);
    }
}

int pop(){
    return stack[current--];
}